home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / networking / news / readers / nn / nn6.4.patch17 < prev    next >
Encoding:
Internet Message Format  |  1993-04-20  |  8.3 KB

  1. From comp.sources.bugs Mon Sep 14 11:35:20 1992
  2. Xref: marlin.jcu.edu.au news.software.nn:3202 comp.sources.bugs:1908
  3. Path: marlin.jcu.edu.au!bunyip.cc.uq.oz.au!munnari.oz.au!uniwa!DIALix!zeus!not-for-mail
  4. From: peter@zeus.DIALix.oz.au (Peter Wemm)
  5. Newsgroups: news.software.nn,comp.sources.bugs
  6. Subject: nn 6.4 - Official patch #17
  7. Date: 13 Sep 1992 11:54:00 +0800
  8. Organization: Karam Pty. Ltd., Perth, Western Australia.
  9. Lines: 253
  10. Message-ID: <18ue0oINN2oe@zeus.dialix.oz.au>
  11. NNTP-Posting-Host: zeus.dialix.oz.au
  12. Summary: Fixes bugs in patch #16 (I hope)
  13. Keywords: nn patch
  14.  
  15.  
  16.          This is an official patch to nn release 6.4
  17.          -------------------------------------------
  18.  
  19.                   PATCH #17
  20.  
  21.                Priority: MEDUIM
  22.  
  23. NOTE: This patch has been posted before, you may have already installed it...
  24. If not, please be aware that future patches (official at least..) will assume
  25. that this has been installed.
  26.  
  27. NN 6.4.16 left a few annoying bugs in the menu selection code.  Many have been
  28. been suffering because of this, and many are missing out on the news features
  29. introduced in Patch #15 - in particular, "consolidated-menus". For those who
  30. are not familiar with these patches, it is a simplistic thread-like extension
  31. to the article viewer to allow collapsing of multiple articles on the same
  32. subject. It is not true threading, however (yet.. :-)
  33.  
  34. This patch, and the following patch #18 were posted last year as unofficial
  35. patches which solve some of the more serious bugs.
  36.  
  37. After some discussions with interested parties, it was decided to re-post
  38. these as as "Official", and clean up a few of the remaining rough edges
  39. in a "Real Soon Now" patch #19.  As quite a few sites have already installed
  40. these patches, (and also many have not...) they were re-posted to help ease
  41. the transition.
  42.  
  43. The contents of this patch are exactly the same as the previous postings.
  44. Do not apply it again...  You do not need to remove the old one and
  45. re-apply.
  46.  
  47. It is reccomended that you install the PAIR of these (17,18) together.
  48. Please also verify that the new version (PL18) is stable on your machine
  49. before commiting to it.
  50.  
  51. cd to your source directory and type "patch < this_article".  Refuse any
  52. reversals...
  53.  
  54. This is the "go-ahead" mail I recieved from Kim:
  55. --------BEGIN--------
  56. ~Date: Fri, 4 Sep 92 08:39:21 GMT
  57. ~From: storm@olicom.dk (Kim F. Storm)
  58. Message-Id: <9209040839.AA05197@olicom.olicom.dk>
  59. To: Peter_Wemm@zeus.dialix.oz.au
  60. Cc: storm@olicom.dk
  61. ~Subject: Kim (that's me)
  62.  
  63. Peter,
  64.  
  65. I would appreciate if you took over the maintenance of nn 6.4.
  66. I have something for the group menu "almost ready" - but it has
  67. been in that state for the last year, and I have to dig into some
  68. old archive tapes to dig out the sources.  Let me see what I can do
  69. about it.
  70.  
  71. In the meantime, I would really appreciate if you would take
  72. on the task of collecting whatever unofficial fixes etc. there have
  73. been for nn 6.4.16 since its release, and put together a set of
  74. OFFICIAL patches ( I hereby grant you the right to stamp patches as
  75. official patches, provided you follow the current style ).
  76.  
  77. ++Kim
  78. ---------END---------
  79.  
  80. >Path: zeus!DIALix!uniwa!munnari.oz.au!spool.mu.edu!yale.edu!qt.cs.utexas.edu!cs.utexas.edu!utgpu!jupiter!morgan.ucs.mun.ca!garfield!larry
  81. >From: larry@garfield.cs.mun.ca (Larry Bouzane)
  82. >Newsgroups: news.software.nn
  83. >Subject: Unofficial patch to fix a few problems with NN version 6.4.16
  84. >Message-ID: <1991Nov14.204714.6850@garfield.cs.mun.ca>
  85. >Date: 14 Nov 91 20:47:14 GMT
  86. >Article-I.D.: garfield.1991Nov14.204714.6850
  87. >Organization: CS Dept., Memorial University of Newfoundland
  88. >Lines: 172
  89.  
  90. Kim seems to have vanished.  Unfortunately there are a few problems with
  91. NN 6.4.16 that just had to be fixed.  The patch below contains fixes for
  92. the following problems:
  93.  
  94. - core dump due to selecting last_article+1 on screen
  95. - core dump due to consolidating (closing) last subject in a group
  96.   under certain circumstances.
  97. - selecting consolidated articles with = command did not highlight
  98.   the selected consolidated articles correctly.
  99. - fixed unconditional CLEAR TO END OF LINE that erased the next line on
  100.   some terminals.  (ie MINE)
  101.  
  102. No guarantees with any of these.  Have fun.  (maybe others out there
  103. with fixes to problems that they noticed would post their fixes as
  104. well)
  105.  
  106. Are you out there Kim?
  107.  
  108. Larry
  109.  
  110. ===================================================================
  111. RCS file: RCS/menu.c,v
  112. retrieving revision 1.1
  113. diff -c -r1.1 menu.c
  114. *** /tmp/,RCSt1004819    Thu Nov 14 16:29:08 1991
  115. --- menu.c    Thu Nov 14 16:29:16 1991
  116. ***************
  117. *** 399,406 ****
  118.       else {
  119.           if (collapse_subject > 0)
  120.           so_printf("%-.*s", collapse_subject, ah->subject);
  121. !         lsubj -= 2 + collapse_subject;
  122. !         so_printf("<>%s", ah->subject + ah->subj_length - lsubj);
  123.       }
  124.       }
  125.   
  126. --- 399,405 ----
  127.       else {
  128.           if (collapse_subject > 0)
  129.           so_printf("%-.*s", collapse_subject, ah->subject);
  130. !         so_printf("<>%s", ah->subject + ah->subj_length - lsubj + collapse_subject + 2);
  131.       }
  132.       }
  133.   
  134. ***************
  135. *** 408,414 ****
  136.       so_printf(ah->lines >= 0 ? " +%d" : " +?", ah->lines);
  137.   
  138.       so_end();
  139. !     if (ah->flag & A_CLOSED) clrline_noflush();
  140.   
  141.    out:
  142.       ah->disp_attr = last_attr;
  143. --- 407,414 ----
  144.       so_printf(ah->lines >= 0 ? " +%d" : " +?", ah->lines);
  145.   
  146.       so_end();
  147. !     if ((ah->flag & A_CLOSED) && lsubj > ah->subj_length)
  148. !         clrline_noflush();
  149.   
  150.    out:
  151.       ah->disp_attr = last_attr;
  152. ***************
  153. *** 455,461 ****
  154.   {
  155.       register article_number i;
  156.       register article_header *ah, **ahp;
  157. !     int count = 0, o_cura;
  158.       extern int kill_file_loaded;
  159.   
  160.       if (mode == 1 && re == NULL) 
  161. --- 455,461 ----
  162.   {
  163.       register article_number i;
  164.       register article_header *ah, **ahp;
  165. !     int count = 0, o_cura, should_mark;
  166.       extern int kill_file_loaded;
  167.   
  168.       if (mode == 1 && re == NULL) 
  169. ***************
  170. *** 462,474 ****
  171.       if (!kill_file_loaded && !init_kill()) return 0;
  172.   
  173.       o_cura = cura;
  174. !     cura = -1;
  175.   
  176.       for (i = 0, ahp = articles; i < n_articles; i++, ahp++) {
  177.       ah = *ahp;
  178. !     if (cura >= 0 && (ah->flag & A_ROOT_ART)) {
  179. !         mark();
  180. !         cura = -1;
  181.       }
  182.       if (re != NULL) {
  183.           if (!regexec_cf(re, select_on_sender ? ah->sender : ah->subject)) continue;
  184. --- 462,481 ----
  185.       if (!kill_file_loaded && !init_kill()) return 0;
  186.   
  187.       o_cura = cura;
  188. !     should_mark = 0;
  189.   
  190. +     /*
  191. +      * note: this code assumes that a visible article will be found
  192. +      * before anything is marked
  193. +      */
  194.       for (i = 0, ahp = articles; i < n_articles; i++, ahp++) {
  195.       ah = *ahp;
  196. !     if (IS_VISIBLE(ah)) {
  197. !         if (should_mark) {
  198. !         mark();
  199. !         should_mark = 0;
  200. !         }
  201. !         cura = i - firsta;
  202.       }
  203.       if (re != NULL) {
  204.           if (!regexec_cf(re, select_on_sender ? ah->sender : ah->subject)) continue;
  205. ***************
  206. *** 478,493 ****
  207.       count++;
  208.       if (ah->attr & A_SELECT) continue;
  209.       ah->attr = A_SELECT;
  210. !     if (firsta <= i && i <= (firsta+numa)) {
  211. !         cura = i - firsta;
  212. !         if ((ah->flag & A_CLOSED) == 0) {
  213. !         mark();
  214. !         cura = -1;
  215. !         }
  216. !     }
  217.       }
  218.   
  219. !     if (cura >= 0) mark();
  220.   
  221.       if (count)
  222.       msg("Selected %d article%s", count, plural((long)count));
  223. --- 485,495 ----
  224.       count++;
  225.       if (ah->attr & A_SELECT) continue;
  226.       ah->attr = A_SELECT;
  227. !     if (firsta <= i && i <= (firsta+numa))
  228. !         should_mark = 1;
  229.       }
  230.   
  231. !     if (should_mark) mark();
  232.   
  233.       if (count)
  234.       msg("Selected %d article%s", count, plural((long)count));
  235. ***************
  236. *** 725,731 ****
  237.       article_id = map & ~K_ARTICLE_ID;
  238.       map = K_ARTICLE_ID;
  239.   
  240. !     if (article_id < 0 || article_id > menu_articles) {
  241.           ding();
  242.           goto loop;
  243.       }
  244. --- 727,733 ----
  245.       article_id = map & ~K_ARTICLE_ID;
  246.       map = K_ARTICLE_ID;
  247.   
  248. !     if (article_id < 0 || article_id >= menu_articles) {
  249.           ding();
  250.           goto loop;
  251.       }
  252. ***************
  253. *** 1639,1644 ****
  254. --- 1641,1647 ----
  255.        }
  256.        cura = article_id;
  257.        next_cura = next_root_article(firsta + cura) - firsta;
  258. +      if (next_cura < 0 || next_cura > numa) next_cura = 0;
  259.        if (cura >= 0) goto partial_redraw_nc;
  260.        articles[cura + firsta]->menu_line = articles[firsta]->menu_line;
  261.        firsta += cura;
  262.  
  263.  
  264. -- 
  265. Peter Wemm : peter@zeus.dialix.oz.au   If it's broke, fix it (The MS-DOS way)
  266. Work phone: +61-9-479-1855    If it aint broke, don't touch it (The Unix way)
  267. Fax: +61-9-479-1134   If we can't fix it, it ain't broke (Maintainer's Motto)
  268. #! rnews 11939
  269. Path: zeus!not-for-mail
  270. ~From: peter@zeus.DIALix.oz.au (Peter Wemm)
  271. ~Newsgroups: news.software.nn,comp.sourc
  272.  
  273.